package com.bluezone.dec.configuration;


import org.springframework.beans.factory.annotation.Value;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.PropertySource;

/**
 * Created by huangr on 2018/7/2.
 */
@Configuration
@PropertySource({"classpath:application.yml"})
public class AppConfig {

    @Value("${app.uac.token.keyName}")
    private String apiKeyName;
    @Value("${app.uac.token.keyUserId}")
    private String apiKeyUserId;
    @Value("${app.uac.token.expire}")
    private Long expired;
    @Value("${app.uac.authUrl}")
    private String authUrl;
    @Value("${app.uac.status}")
    private boolean uacStatus;


    /* 监控预警 */
    @Value("${monitor.gasCode}")
    private String gasCode;
    @Value("${monitor.waterCode}")
    private String waterCode;

    /* redis图表数据缓存时间 */
    @Value("${app.chartData.chartDataCacheTime}")
    private Long chartDataCacheTime;

    /* 企业数据缓存时间 */
    @Value("${enterprise.enterpeiseDataCacheTime}")
    private Long enterpriseDataCacheTime;

    @Value("${dse.ip}")
    private String dseIp;


    public String keyName() {
        return apiKeyName;
    }

    public String getApiKeyUserId() {
        return apiKeyUserId;
    }


    public Long getExpired() {
        return expired;
    }


    public boolean getUacStatus() {
        return uacStatus;
    }


    public String getDseIp() {
        return dseIp;
    }

    public void setDseIp(String dseIp) {
        this.dseIp = dseIp;
    }


    public Long getChartDataCacheTime() {
        return chartDataCacheTime;
    }

    public Long getEnterpriseDataCacheTime() {
        return enterpriseDataCacheTime;
    }

    public String getGasCode() {
        return gasCode;
    }

    public String getWaterCode() {
        return waterCode;
    }
}
